﻿<UserControl x:Class="Starehe.Views.AllEvents"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" d:DesignHeight="700" d:DesignWidth="984"
             Background="White">
    <UserControl.Resources>
        <ResourceDictionary Source="/Starehe;component/ModelsDataTemplates.xaml"/>
    </UserControl.Resources>
    <Grid>
        <TextBlock HorizontalAlignment="Left" Margin="20,20,0,0" Style="{DynamicResource Title}"  Text="All Events" 
                   VerticalAlignment="Top"/>
        <ListBox BorderBrush="Silver" BorderThickness="2" VirtualizingPanel.IsVirtualizing="True" Margin="39,80,40,40" ItemsSource="{Binding AllEvents}" 
                 ItemTemplate="{StaticResource EventTemplate}">
            <ListBox.ItemsPanel>
                <ItemsPanelTemplate>
                    <VirtualizingStackPanel IsItemsHost="True"/>
                </ItemsPanelTemplate>
            </ListBox.ItemsPanel>
        </ListBox>
    </Grid>
</UserControl>